﻿using System;
using System.Collections.Generic;

namespace FallingRox
{
    public class Rock : MoveableObject
    {
        //to do : to create a 3d char list wich will have some rock templates
        public readonly List<char[,]> templates = new List<char[,]>
        {
           new char[,] {{'#','#','#'}, {' ','#','#'}},
           new char[,] {{'$','$','$'}, {' ','$',' '}},
           new char[,] {{'*',' '}, {'*','*'}},
           new char[,] {{'%',' '}, {'%','%'}},
           new char[,] {{'x',' '}, {'x','x'}, {' ','x'}}
        };

        public Rock(MatrixCoords position, int template)
        {
            this.Position = position;
            this.Body = templates[template];
            this.IsDestroyed = false;
        }

        public override void RespondToCollision()
        {
            this.IsDestroyed = true;
        }
    }
}
